package com.example.web.sys_menu.mapper;

import com.example.web.sys_menu.entity.Menu;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * <p>
 *  Mapper 接口
 * </p>
 *
 * @author LS
 * @since 2024-02-20
 */
public interface MenuMapper extends BaseMapper<Menu> {

    //根据用户id查询菜单
    List<Menu> getMenuByUserId(@Param("userId") Long userId);
    //根据角色id查询菜单
    List<Menu> getMenuByRoleId(@Param("roleId") Long roleId);

}
